﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace C4F.VistaP2P.Win
{
    public class Utility
    {
        private delegate void SetTextLabelHandler(Label l, string valueToSet);
        public static void SetTextLabel(Label l, string valueToSet)
        {
            if (l.InvokeRequired)
            {
                l.Invoke(new SetTextLabelHandler(SetTextLabel), new object[] {l, valueToSet});
            }
            else
            {
                l.Text = valueToSet;
            }
        }
    }
}
